package com.hesicare.untils.exceptionUtils;

/**
 * @Author 55097
 * @create 2022/1/5 21:57
 */
public class exceptionutil {

    public static String errorTrackSpace(Exception e) {
        StringBuffer sb = new StringBuffer();
        if (e != null) {
            for (StackTraceElement element : e.getStackTrace()) {
                sb.append("\r\n\t").append(element);
            }
        }
        return sb.length() == 0 ? null : sb.toString();
    }
}
